﻿using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace Entity
{
    public class EntityBase
    {
        public EntityBase()
        {
            this.ID = Guid.NewGuid();
            this.IsLock = false;
            this.IsDelete = false;
            this.CreatTime = DateTime.Now;
        }

        [Column("P01")]
        [Key]
        [DatabaseGenerated(DatabaseGeneratedOption.None)]
        public Guid ID { get; set; }
        [Column("P02")]
        public Boolean IsLock { get; set; }
        [Column("P03")]
        public bool IsDelete { get; set; }
        [Required]
        [Column("P04")]
        public DateTime CreatTime { get; set; }
    }
}
